/*
 * @描述: 城市管理 service层
 * @Author: /zlh
 * @Date: 2021-06-17 09:26:22
 * @Last Modified by: zlh
 * @Last Modified time: 2021-06-17 11:55:58
 */
import request from '@/utils/request';
import { secMap } from '@/configs/api.map';
const { api_censusBugMsg, api_getDayBugByPage, api_decryptBugById, api_updateBugState, api_updateBugRemark } = secMap;
/**
 * @description 获取bug列表
 * @author zlh
 * @date 2021-06-15
 * @export
 * @param {object} channel
 * @returns
 */
export async function getCensusBugMsg(channel) {
  return request(api_censusBugMsg, {
    method: 'POST',
    data: {
      ...channel,
    },
  });
}
/**
 * @description 每日bug
 * @author zlh
 * @date 2021-04-29
 * @export
 * @param {object} channel
 * @returns
 */
export async function getDayBugByPage(channel) {
  return request(api_getDayBugByPage, {
    method: 'POST',
    data: {
      ...channel,
    },
  });
}
/**
 * @description bug解密
 * @author zlh
 * @date 2021-04-29
 * @export
 * @param {object} id
 * @returns
 */
export async function decryptBugById(id) {
  return request(api_decryptBugById, {
    method: 'POST',
    data: {
      id
    },
  });
}
/**
 * @description 修改bug信息
 * @author zlh
 * @date 2021-04-29
 * @export
 * @param {object} data
 * @returns
 */
export async function updateBugState(data) {
  return request(api_updateBugState, {
    method: 'POST',
    data
  });
}

/**
 * @description 修改备注信息
 * @author zlh
 * @date 2021-10-11
 * @export
 * @param {object} data
 * @returns
 */
export async function updateBugRemark(data) {
  return request(api_updateBugRemark, {
    method: 'POST',
    data
  });
}